home *** CD-ROM | disk | FTP | other *** search
- /*=======================================================================*/
- /* */
- /* (c) InstallShield Software Corporation (1996-1997) */
- /* (c) InstallShield Corporation (1990-1996) */
- /* Schaumburg, Illinois 60173 */
- /* All Rights Reserved */
- /* InstallShield (R) */
- /* */
- /* File : sdscopy.rul */
- /* */
- /* Purpose : This file contains the code for the SdStartCopy */
- /* script dialog function. */
- /* */
- /*-------------------------------------------------------------------------
-
- /*------------------------------------------------------------------------*/
- /* */
- /* Function: SdStartCopy */
- /* */
- /* Descrip: This dialog will infom the user about the data they have */
- /* selected and allow them a last chance to modify their */
- /* settings. */
- /* Misc: */
- /* */
- /*------------------------------------------------------------------------*/
- function SdStartCopy( szTitle, szMsg, listData )
- STRING szDlg, szTemp;
- INT nId, list;
- BOOL bDone;
- HWND hwndChild, hwndDlg;
- begin
-
- szDlg = SD_DLG_STARTCOPY;
- nSdDialog = SD_NDLG_STARTCOPY;
-
- // record data produced by this dialog
- if (MODE=SILENTMODE) then
- SdMakeName( szAppKey, szDlg, szTitle, nSdStartCopy );
- SilentReadData( szAppKey, "Result", DATA_NUMBER, szTemp, nId );
- return nId;
- endif;
-
- // ensure general initialization is complete
- if (!bSdInit) then
- SdInit();
- endif;
-
- if (EzDefineDialog( szDlg, "", "", SD_NDLG_STARTCOPY) = DLG_ERR) then
- return -1;
- endif;
-
- // Loop in dialog until the user selects a standard button
- bDone = FALSE;
-
- while (!bDone)
-
- nId = WaitOnDialog( szDlg );
-
- switch (nId)
- case DLG_INIT:
- if(szMsg != "") then
- SdSetStatic( szDlg, SD_STA_MSG1, szMsg );
- endif;
-
- hwndDlg = CmdGetHwndDlg( szDlg );
- SdGeneralInit( szDlg, hwndDlg, 0, szSdProduct );
-
- if(szTitle != "") then
- SetWindowText( hwndDlg, szTitle );
- endif;
-
- if (listData = 0) then
- hwndChild = GetDlgItem( hwndDlg, SD_MULTEDIT_FIELD1 );
- ShowWindow( hwndChild, SW_HIDE );
- hwndChild = GetDlgItem( hwndDlg, SD_STA_SETTINGS );
- ShowWindow( hwndChild, SW_HIDE );
- else
- CtrlSetMLEText( szDlg, SD_MULTEDIT_FIELD1, listData );
- endif;
-
- case SD_PBUT_CONTINUE:
- nId = NEXT;
- bDone = TRUE;
-
- case BACK:
- nId = BACK;
- bDone = TRUE;
-
- case DLG_ERR:
- SdError( -1, szDlg );
- nId = -1;
- bDone = TRUE;
-
- case DLG_CLOSE:
- SdCloseDlg( hwndDlg, nId, bDone );
-
- default:
- // check standard handling
- if (SdIsStdButton( nId ) && SdDoStdButton( nId )) then
- bDone = TRUE;
- endif;
- endswitch;
-
- endwhile;
-
- EndDialog( szDlg );
- ReleaseDialog( szDlg );
-
- SdUnInit();
-
- // record data produced by this dialog
- SdMakeName( szAppKey, szDlg, szTitle, nSdStartCopy );
- SilentWriteData( szAppKey, "Result", DATA_NUMBER, "", nId );
-
- return nId;
- end;
-
-